package com.um.info.action;

import javax.annotation.Resource;

import com.cs.framework.ui.bo.UIData;
import com.cs.framework.web.annotation.Action;
import com.cs.framework.web.annotation.Mapping;
import com.cs.framework.web.handler.Web;
import com.um.info.service.UmMenuService;

/**
 * UM菜单
 * 
 * @author hedongzhou
 * 
 */
@Action("umMenu")
public class UmMenuAction {

	@Resource
	private UmMenuService umMenuService;

	/**
	 * 查询用户可见菜单列表
	 * 
	 * @return
	 */
	@Mapping
	public Object getCanSeeMenu() {
		return new UIData(umMenuService.getCanSeeMenu("0", Web.getUserId()));
	}

	/**
	 * 查询用户可配置菜单列表
	 * 
	 * @return
	 */
	@Mapping
	public Object getCanSetMenu() {
		return new UIData(umMenuService.getCanSetMenu("0", Web.getParameter("userId")));
	}

}
